import QtQuick 2.15
import QtQuick.Controls.Basic

Button {

    background: Rectangle {
        color: parent.pressed ? "#232323" : (parent.hovered ? "#434343" : "#333333")
        border.width: 1
        border.color: color
        anchors.fill: parent
        radius: 5
    }

    width: Constants.width
    height: Constants.height
    property string hoveredIcon: ""
    property string pressedIcon: ""
    property string normalIcon: ""

    property int imageHeight: -1
    property int imageWidth: -1

    Image {
        id: btnIcon
        source: parent.pressed ? pressedIcon : parent.hover ? hoveredIcon : normalIcon
        mipmap: true
        anchors.centerIn: parent
        width: imageWidth <= -1 ?  parent.width : imageWidth
        height: imageHeight <= -1 ? parent.height : imageHeight
    }
}

/*##^##
Designer {
    D{i:0;formeditorZoom:0.75}
}
##^##*/

